<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>Document</title>
    <style>
        * {
            margin: 0;
            padding: 0;
        }

        body {
            background-color: #252525;
            min-height: 100vh;
            display: flex;
            align-items: center;
            justify-content: center;
            color: #ffffde;
            gap: 0 12px;
        }

        .container {
            background-color: inherit;
            position: relative;
            display: flex;
            align-items: center;
            flex-direction: column;
            overflow: hidden;
            width: 100px;
            height: 300px;
            mask-image: linear-gradient(180deg, transparent, #fff 20%, #fff 80%, transparent);
            /* mask-image: linear-gradient(180deg, transparent, #000 20%, #000 80%, transparent); */
            /* background-image: linear-gradient(180deg, transparent, blue 20%, purple 80%, transparent); */

        }

        .container div {
            white-space: nowrap;
            display: flex;
            flex-direction: column;
            animation: scrollUp var(--t) linear infinite;
        }

        .container div:nth-child(2) {
            animation: scrollUp2 var(--t) linear infinite;
            animation-delay: calc(var(--t) / -2);
        }

        @keyframes scrollUp {
            from {
                transform: translateY(100%);
            }

            to {
                transform: translateY(-100%);
            }
        }


        @keyframes scrollUp2 {
            from {
                transform: translateY(0%);
            }

            to {
                transform: translateY(-200%);
            }
        }

        .container div span {
            display: inline-flex;
            background-color: #333;
            letter-spacing: 0.2em;
            margin: 10px;
            border-radius: 5px;
            padding: 5px 10px;
        }
    </style>
</head>

<body>
    <!-- 第一列 -->
    <div class="container" style="--t:16s">
        <div>
            <span>Lorem1</span>
            <span>Lorem2</span>
            <span>Lorem4</span>
            <span>Lorem5</span>
            <span>Lorem6</span>
            <span>Lorem7</span>
            <span>Lorem8</span>
            <span>Lorem9</span>
        </div>
        <div>
            <span>Lorem1</span>
            <span>Lorem2</span>
            <span>Lorem4</span>
            <span>Lorem5</span>
            <span>Lorem6</span>
            <span>Lorem7</span>
            <span>Lorem8</span>
            <span>Lorem9</span>
        </div>
    </div>



    <div class="container" style="--t:12s">
        <div>
            <span>Lorem1</span>
            <span>Lorem2</span>
            <span>Lorem4</span>
            <span>Lorem5</span>
            <span>Lorem6</span>
            <span>Lorem7</span>
            <span>Lorem8</span>
            <span>Lorem9</span>
        </div>
        <div>
            <span>Lorem1</span>
            <span>Lorem2</span>
            <span>Lorem4</span>
            <span>Lorem5</span>
            <span>Lorem6</span>
            <span>Lorem7</span>
            <span>Lorem8</span>
            <span>Lorem9</span>
        </div>
    </div>



    <div class="container" style="--t:8s">
        <div>
            <span>Lorem1</span>
            <span>Lorem2</span>
            <span>Lorem4</span>
            <span>Lorem5</span>
            <span>Lorem6</span>
            <span>Lorem7</span>
            <span>Lorem8</span>
            <span>Lorem9</span>
        </div>
        <div>
            <span>Lorem1</span>
            <span>Lorem2</span>
            <span>Lorem4</span>
            <span>Lorem5</span>
            <span>Lorem6</span>
            <span>Lorem7</span>
            <span>Lorem8</span>
            <span>Lorem9</span>
        </div>
    </div>




    <div class="container" style="--t:4s">
        <div>
            <span>Lorem1</span>
            <span>Lorem2</span>
            <span>Lorem4</span>
            <span>Lorem5</span>
            <span>Lorem6</span>
            <span>Lorem7</span>
            <span>Lorem8</span>
            <span>Lorem9</span>
        </div>
        <div>
            <span>Lorem1</span>
            <span>Lorem2</span>
            <span>Lorem4</span>
            <span>Lorem5</span>
            <span>Lorem6</span>
            <span>Lorem7</span>
            <span>Lorem8</span>
            <span>Lorem9</span>
        </div>
    </div>
</body>

</html>